#define _CRT_SECURE_NO_WARNINGS 1
int digit(int n, int k)
{
	if (n == 0)
		return -1;
	else if (k == 1)
		return (n % 10);
	else
		digit(n / 10, k - 1);
}